//
//  AppError.swift
//  SwiftUI-Pokemaster
//
//  Created by gree on 2020/10/10.
//

import Foundation

enum MyAppError: Error, Identifiable {
    var id: String{localizedDescription}
    
    case passwordWrong
}

extension MyAppError: LocalizedError {
    var localizedDescription: String {
        switch self {
            case .passwordWrong:
                return "密码错误"
        }
    }
}
